
import axiosRequest from "@/api/axios-optimize"

// 获取回收站列表
export function getRecycleBinList(
  data = {},
  config = {
    noShowLoading: true, // 配置不展示加载动画
    preventDuplicateRequestsType: "cancel" // 配置重复请求时 取消前面的请求
  }
) {
  return axiosRequest.get(`/xiaobuAdmin/recycleBin/getRecycleBinList`, { params: data, ...config })
}

// 批量删除回收站数据
export function batchDelete(data = {}, config = {
  preventDuplicateRequestsType: "prevent"
}) {
  return axiosRequest.post(
    `/xiaobuAdmin/recycleBin/batchDelete`,
    data,
    config
  )
}

// 批量还原回收站数据
export function batchRestore(data = {}, config = {
  preventDuplicateRequestsType: "prevent"
}) {
  return axiosRequest.post(
    `/xiaobuAdmin/recycleBin/batchRestore`,
    data,
    config
  )
}